﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using App.Interface;

namespace App.Realization
{
    public class FuJiaXiangtmpl : IFuJiaXiang
    {
        public string GetFuJiaXiangs()
        {
            var result = HttpClientHelper.GetResponse(
                System.Web.Configuration.WebConfigurationManager.AppSettings["schoolapi"] + "/api/FuJiaXiang/GetFuJiaXiangs");
            return result;
        }
        public void AddFuJiaXiang(string str)
        {
            var reslut = HttpClientHelper.PostResponse(System.Web.Configuration.WebConfigurationManager.AppSettings["schoolapi"] + "/api/FuJiaXiang/SaveFuJiaXiang", str);
        }

        public void DelFuJiaXiang(int fjxid)
        {
            var result = HttpClientHelper.GetResponse(System.Web.Configuration.WebConfigurationManager.AppSettings["schoolapi"] + "/api/FuJiaXiang/DelFuJiaXiang?fjxid=" + fjxid);
        }

        public void MyKaoHeBiaoAddFuJiaXiang(int mkhbid, int xmid, decimal fz, string username)
        {
            var result = HttpClientHelper.GetResponse(System.Web.Configuration.WebConfigurationManager.AppSettings["schoolapi"] + "/api/FuJiaXiang/AddMyKHBFJX?mkhbid=" + mkhbid + "&xmid=" + xmid + "&fz=" + fz + "&username=" + username);
        }

        public void MyKaoHeBiaoDelFuJiaXiang(int mkhbid, int fjxid)
        {
            var result = HttpClientHelper.GetResponse(System.Web.Configuration.WebConfigurationManager.AppSettings["schoolapi"] + "/api/FuJiaXiang/DelMyKHBFJX?mkhbid=" + mkhbid + "&fjxid=" + fjxid);
        }

        public string GetMyKHBFJXs(int mkhbid)
        {
            var result = HttpClientHelper.GetResponse(System.Web.Configuration.WebConfigurationManager.AppSettings["schoolapi"] + "/api/FuJiaXiang/GetMyKHBFJXs?mkhbid=" + mkhbid );
            return result;
        }
    }
}
